﻿@using KXCXW.Web.CommonClass
@{
    
    AdHelper ah = new AdHelper(Server.MapPath("~/Content/xml/Adconfig.xml"));
    AdModel am = ah.getAdModelByBlockId(Model);
    if (am != null)
    {
    <a href="@am.href" target="_blank" title="@am.name" style="width:@(am.width.ToString() + "px");height:@(am.height.ToString() + "px");display:block;float: left;">
        @if (am.id.IndexOf('B') > 0)
        {
            <textarea class="switch_textarea"><img src="@Url.Content(am.src)" alt="@am.name" style="width:@(am.width.ToString() + "px");height:@(am.height.ToString() + "px")"/></textarea>
        }
        else
        {
            <img src="@Url.Content(am.src)" alt="@am.name" style="width:@(am.width.ToString() + "px");height:@(am.height.ToString() + "px")"/>
        }
    </a>
        if (am.id.IndexOf('A') < 0)
        {
    <div style="height: 8px; float: left; width: 100px;">
    </div>
        }
    }
}
